<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    <head>
        <title>#{get 'title' /}</title>		
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
        <link rel="stylesheet" type="text/css" media="screen" 
            href="@{'/public/stylesheets/main.css'}" />
        <link rel="shortcut icon" type="image/png" 
            href="@{'/public/images/favicon.png'}" />
    </head>
    <body>
        
        <div id="header">
            <div id="logo">
				${covamiTitle}
            </div>
            <ul id="tools">
	            <!--Si on est connecté, on dit bonjour et on propose de se déconnecter -->
	            <li>
					#{if security != null}
						<a href="@{Admin.index()}">Administration</a>&nbsp;&nbsp;&nbsp;
						<a href="@{Secure.logout()}">Déconnexion [${user.email}]</a>
					#{/if}
					<!-- Sinon on propose de se logger -->
					#{else}
						<a href="@{Secure.login()}">Connexion</a>&nbsp;&nbsp;&nbsp;
						<a href="@{Application.inscription()}">S'inscrire</a>
					#{/else}
                </li>
                
            </ul>
            <div id="title">
                <span class="about">About this blog</span>
                 	<ul id="adminMenu">
                 	#{if security != null}
		            	<li class="${request.controller == 'Utilisateurs' ? 'selected' : ''}">
		                	<a href="@{Application.moncompte()}">Mon compte</a>
		                </li>
		         	#{/if}
		    		</ul>
		    	<h2>${covamiBaseline}</h2>
            </div>
        </div>
        
        <div id="main">
            #{doLayout /} 
        </div>
        
        <p id="footer">
            Gaudéric Pledran - Philippe Chauvelin - Mélina Fontaine
        </p>
        
    </body>
</html>